package com.cd.university.controller.form;

import lombok.Data;

import javax.validation.constraints.Pattern;

/**
 * @author 陈栋
 * @create 2021/11/22 14:27
 */
@Data
public class UserBasicInfoForm {

    /**
     * 用户唯一id，自增约束
     */
    private Integer userId;

    /**
     * 用户账号
     */
    private String username;

    /**
     * 用户邮箱
     */
    @Pattern(regexp = "^[A-Za-z0-9_-]+@[a-zA-Z0-9_-]+(\\.[a-zA-Z0-9_-]+)+$",message = "必须要符合标准的邮件格式")
    private String userEmail;

    /**
     * 用户电话
     */
    @Pattern(regexp = "^[\\d\\*]{7,12}$",message = "电话验证符合规范")
    private String userMobile;
}
